home *** CD-ROM | disk | FTP | other *** search
/ BCI NET / BCI NET Dec 94.iso / archives / programming / libraries / bgui10.lha / docs / frameclass.doc < prev    next >
Encoding:
Text File  |  1994-07-16  |  8.2 KB  |  296 lines

  1.  
  2.            $RCSfile: frameclass.doc,v $
  3.         Description: Frameclass documentation.
  4.           Copyright: (C) Copyright 1994 Jaba Development.
  5.                      (C) Copyright 1994 Jan van den Baard.
  6.                      All Rights Reserved.
  7.  
  8.             $Author: jaba $
  9.           $Revision: 1.2 $
  10.               $Date: 1994/07/16 17:43:14 $
  11. ------------------------------------------------------------------------------
  12.  
  13. TABLE OF CONTENTS
  14.  
  15. frameclass/--background--
  16. frameclass/Methods
  17. frameclass/Attributes
  18.  
  19. frameclass/--background--                            frameclass/--background--
  20.  
  21.     NAME
  22.         Class:          frameclass
  23.         Superclass:     IMAGECLASS
  24.         Include File:   <libraries/bgui.h>
  25.  
  26.     FUNCTION
  27.         To  provide   a   general   framing  image.  It  has a set of built-in
  28.         framing  and  background  types  and  the  possibility  to  add  hooks
  29.         for custom frames and backgrounds.
  30.  
  31. frameclass/Methods                                          frameclass/Methods
  32.  
  33.     NEW METHODS
  34.         None.
  35.  
  36.     CHANGED METHODS
  37.         None.
  38.  
  39. frameclass/Attributes                                    frameclass/Attributes
  40.  
  41.     NAME
  42.         FRM_Type - ( ULONG )
  43.  
  44.     FUNCTION
  45.         Set  or  get  the  type of the used framing. You can select any of the
  46.         following types:
  47.  
  48.         FRTYPE_CUSTOM --  This is a custom framing type which is automatically
  49.                 set when you supply a framing hook.
  50.  
  51.         FRTYPE_BUTTON -- Standard button gadget frame.
  52.  
  53.         FRTYPE_RIDGE -- Standard string gadget frame.
  54.  
  55.         FRTYPE_DROPBOX -- Standard icon-dropbox frame.
  56.  
  57.         FRTYPE_NEXT -- Standard  NeXT  frame  which  basically  is an inverted
  58.                 (recessed) string gadget frame.
  59.  
  60.         FRTYPE_RADIOBUTTON -- Standard MX gadget frame.
  61.  
  62.         FRTYPE_XEN_BUTTON -- XEN style button frame.
  63.  
  64.         Default is FRTYPE_BUTTON. Applicability is (ISG).
  65.  
  66.     SEE ALSO
  67.         FRM_CustomHook
  68.  
  69.     NAME
  70.         FRM_CustomHook, FRM_BackFillHook -- ( struct Hook * )
  71.  
  72.     FUNCTION
  73.         Set or get custom framing and/or backfilling hooks.  These  hooks  are
  74.         called as follows:
  75.  
  76.         rc = hookFunc( hook, object, message );
  77.         D0             A0    A2      A1
  78.  
  79.         The  message  packet  can  be  a  pointer  to  any  of  the  following
  80.         structures:
  81.  
  82.         struct FrameDrawMsg {
  83.                 ULONG             fdm_MethodID; /* FRM_RENDER */
  84.                 struct RastPort  *fdm_RPort;
  85.                 struct DrawInfo  *fdm_DrawInfo;
  86.                 struct Rectangle *fdm_Bounds;
  87.                 UWORD             fdm_State;
  88.         };
  89.  
  90.         fdm_RPort -- This points to the RastPort in which the frame/background
  91.                 must be rendered.
  92.  
  93.         fdm_DrawInfo --  This  points  to  a  DrawInfo structure as defined in
  94.                 <intuition/screens.h>
  95.  
  96.         fdm_Bounds -- This points to a Rectangle structure in which the bounds
  97.                 of the frame/background are stored.
  98.  
  99.         fdm_State -- This holds the state in which you should render the frame
  100.                 or background.  Please  refer  to <intuition/imageclass.h> for
  101.                 more information about rendering styles.
  102.  
  103.         The  FrameDrawMsg  is  sent to both the custom and backfill hooks when
  104.         they must render.
  105.  
  106.         struct ThicknessMsg {
  107.                 ULONG             tm_MethodID; /* FRM_THICKNESS */
  108.                 struct {
  109.                         UBYTE    *Horizontal;
  110.                         UBYTE    *Vertical;
  111.                 }                 tm_Thickness;
  112.         };
  113.  
  114.         tm_Thickness -- In  this  field  you  must store the thickness  of the
  115.                 frame lines. The thickness requested is the width in pixels of
  116.                 the left OR right border (Vertical) and the  height in  pixels
  117.                 of the top OR bottom border (Horizontal).
  118.  
  119.         The ThicknessMsg is only sent to the custom frame hook.
  120.  
  121.         The hook routines must return any of the following return codes:
  122.  
  123.         FRC_OK -- OK. Message understood and executed.
  124.  
  125.         FRC_UNKNOWN -- Message not understood. The class will default in  this
  126.                 case.
  127.  
  128.         Defaults are NULL. Applicability is (ISG)
  129.  
  130.     SEE ALSO
  131.         <intuition/screens.h>, <intuition/imageclass.h>
  132.  
  133.     NAME
  134.         FRM_Title -- ( STRPTR )
  135.  
  136.     FUNCTION
  137.         Set  or  get  the  frame  title.  Each  frame can have a title in it's
  138.         top-border. With this attribute you set that title.
  139.  
  140.         Default is NULL. Applicability is (ISG).
  141.  
  142.     SEE ALSO
  143.         FRM_TextAttr
  144.  
  145.     NAME
  146.         FRM_TextAttr -- ( struct TextAttr * )
  147.  
  148.     FUNCTION
  149.         Set  or  get  the  font that is used to render the frame title. Please
  150.         note  that  this font is opened width OpenFont() and must be available
  151.         in memory.
  152.  
  153.     SEE ALSO
  154.         FRM_Title
  155.  
  156.     NAME
  157.         FRM_Flags -- ( ULONG )
  158.  
  159.     FUNCTION
  160.         To initialize any of the following flags:
  161.  
  162.         FRF_EDGES_ONLY -- When  this  flag  is  set  only the frame border are
  163.                 rendered. The background isn't touched.
  164.  
  165.         FRF_RECESSED -- Normally the frame is raised.  With  this flag set the
  166.                 frame is recessed by default.
  167.  
  168.         FRF_CENTER_TITLE -- Normally the frame title is rendered with the text
  169.                 baseline on the top border of the frame. When this flag is set
  170.                 the title is cenetered on the top border of the frame.
  171.  
  172.         FRF_HIGHLIGHT_TITLE -- Normally the frame title is  rendered  with the
  173.                 TEXTPEN. When this flag is set the title is rendered using the
  174.                 HIGHLIGHTTEXTPEN.
  175.  
  176.         FRF_THIN_FRAME -- This  flag, when set,  will  halve  the  size of the
  177.                 vertical borders of the frame.  This  looks  a  lot  better on
  178.                 screens width a 1:1 aspect ratio.
  179.  
  180.         Default is 0. Applicability is (ISG).
  181.  
  182.     SEE ALSO
  183.         <intuition/screens.h>,    FRM_Title,    FRM_EdgesOnly,   FRM_Recessed,
  184.         FRM_CenterTitle, FRM_HighlightTitle, FRM_ThinFrame
  185.  
  186.     NAME
  187.         FRM_FrameWidth -- ( UBYTE )
  188.  
  189.     FUNCTION
  190.         Get the width in pixels of the left or right frame border.
  191.  
  192.         Applicability is (G).
  193.  
  194.     SEE ALSO
  195.         FRM_FrameHeight
  196.  
  197.     NAME
  198.         FRM_FrameHeight -- ( UBYTE )
  199.  
  200.     FUNCTION
  201.         Get the height in pixels of the top or bottom frame border.
  202.  
  203.         Applicability is (G).
  204.  
  205.     SEE ALSO
  206.         FRM_FrameWidth
  207.  
  208.     NAME
  209.         FRM_BackFill -- ( ULONG )
  210.  
  211.     FUNCTION
  212.         Set or get the built-in background type to use.  You can select any of
  213.         the following types:
  214.  
  215.         STANDARD_FILL -- Normal fill as you  would  expect  from the  selected
  216.                 frame type.
  217.  
  218.         SHINE_RASTER -- A raster with the SHINEPEN and BACKGROUNDPEN.
  219.  
  220.         SHADOW_RASTER -- A raster with the SHADOWPEN and BACKGROUNDPEN.
  221.  
  222.         SHINE_SHADOW_RASTER -- A raster with the SHINEPEN and SHADOWPEN.
  223.  
  224.         FILL_RASTER -- A raster with the FILLPEN and BACKGROUNDPEN.
  225.  
  226.         SHINE_FILL_RASTER -- A rster with the SHINEPEN and FILLPEN.
  227.  
  228.         SHADOW_FILL_RASTER -- A raster with the SHADOWPEN and FILLPEN.
  229.  
  230.         SHINE_BLOCK -- A SHINEPEN fill.
  231.  
  232.         SHADOWBLOCK -- A SHADOWPEN fill.
  233.  
  234.         Please  note  that  setting any of the above backfill types except for
  235.         STANDARD_FILL will override the FRM_BackFillHook.
  236.  
  237.         Default is STANDARD_FILL. Applicability is (ISG).
  238.  
  239.     SEE ALSO
  240.         <intuition/screens.h>, FRM_BackFillHook
  241.  
  242.     NAME
  243.         FRM_EdgesOnly -- ( BOOL )
  244.  
  245.     FUNCTION
  246.         Set or clear the FRF_EDGES_ONLY flags.
  247.  
  248.         Default is FALSE. Applicability is (ISG).
  249.  
  250.     SEE ALSO
  251.         FRM_Flags
  252.  
  253.     NAME
  254.         FRM_Recessed -- ( BOOL )
  255.  
  256.     FUNCTION
  257.         Set or clear the FRF_RECESSED flag.
  258.  
  259.         Default is FALSE. Applicability is (ISG).
  260.  
  261.     SEE ALSO
  262.         FRM_Flags
  263.  
  264.     NAME
  265.         FRM_CenterTitle - ( BOOL )
  266.  
  267.     FUNCTION
  268.         Set or clear the FRF_CENTER_TITLE flag.
  269.  
  270.         Default is FALSE. Applicability is (ISG).
  271.  
  272.     SEE ALSO
  273.         FRM_Flags
  274.  
  275.     NAME
  276.         FRM_HighlightTitle -- ( BOOL )
  277.  
  278.     FUNCTION
  279.         Set or clear the FRF_HIGHLIGHT_TITLE flag.
  280.  
  281.         Default is FALSE. Applicability is (ISG).
  282.  
  283.     SEE ALSO
  284.         FRM_Flags
  285.  
  286.     NAME
  287.         FRM_ThinFrame -- ( BOOL )
  288.  
  289.     FUNCTION
  290.         Set or clear the FRF_THIN_FRAME flag.
  291.  
  292.         Default is FALSE. Applicability is (ISG).
  293.  
  294.    SEE ALSO
  295.         FRM_Flags
  296.